using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

namespace WebApplication1
{
    public partial class KYCTextBox : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }
        String name = String.Empty;
        String cssClass = String.Empty;
        String id = String.Empty;
        bool isRequire = false;
        String requireMessage = String.Empty;



        public String Name
        {
            get { return name; }
            set { name = value; }
        }

        public String RequireMessage
        {
            get { return requireMessage; }
            set { requireMessage = value; }
        }

        public String ControlID
        {
            get { return id; }
            set { id = value; }
        }

        public bool IsRequire
        {
            get { return isRequire; }
            set { isRequire = value; }
        }

        public String CssClass
        {
            get { return cssClass; }
            set { cssClass = value; }
        }

        protected override void OnInit(EventArgs e)
        {
            base.OnInit(e);
            textBoxControl.ID = id;
            textBoxControl.CssClass = cssClass;
            localizeControl.ID = "localize" + name;
            requiredfieldvalidatorControl.ID = "requiredfieldvalidator" + name;
            requiredfieldvalidatorControl.ControlToValidate = textBoxControl.ID;
            requiredfieldvalidatorControl.ErrorMessage = requireMessage;
        }

        protected override void OnPreRender(EventArgs e)
        {
            localizeControl.Text = name;
            base.OnPreRender(e);
        }

        
    }
}